import Vue from 'vue'
import App from './App.vue'
import router from './router'
import store from './store'

import vueLazyLoad from 'vue-lazyload'
import Fastclick from 'fastclick'

import toast from 'components/common/toast'
import 'vant/lib/index.css';
import { Swipe, SwipeItem } from 'vant';

Vue.use(Swipe);
Vue.use(SwipeItem);

Vue.config.productionTip = false

//添加事件总线对象
Vue.prototype.$bus = new Vue()
//安装toast插件
Vue.use(toast)

//解决移动端300ms延迟
Fastclick.attach(document.body)

//使用图片懒加载的插件
Vue.use(vueLazyLoad, {
	loading:require('./assets/img/common/placeholder.png')//图片没加载完成默认用着张
})

new Vue({
  router,
  store,
  render: h => h(App)
}).$mount('#app')
